<template>
	<view>
		<!-- 订单状态 -->
		<view class="status">
			<h1>订单已经完成</h1>
			<text>感谢你对本店的支持，欢迎再次光临</text>
		</view>
		<!-- 商品信息 -->
		<view class="proInfo">
			<view class="shop">
				<view class="detail">
					<h1>壹方城</h1>
					<p>深圳宝安区宝安中心A出口壹方城1F28</p>
				</view>
				<view class="icons">
					<uni-icons color="#bababa" type="phone" size="30" @click="phone('19327528015')"></uni-icons>
					<uni-icons color="#bababa" type="navigate" size="30"></uni-icons>
				</view>
			</view>
			<view style="width: 100%; height: 1rpx; background-color: #f8f8f8; margin: 10rpx 0rpx;"></view>
			<view class="payinfo">
				<image src="https://placehold.co/50x50"></image>
				<text>芒芒甘露冰棒</text>
				<view class="right">
					<text class="price">￥18</text>
					<text class="desc">x1</text>
				</view>
			</view>
			<view style="width: 100%; height: 1rpx; background-color: #f8f8f8; margin: 10rpx 0rpx;"></view>
			<!-- total -->
			<view class="total">
				<view class="left">
					商品总价
				</view>
				<view class="right">
					￥18
				</view>
			</view>
			<view style="width: 100%; height: 1rpx; background-color: #f8f8f8; margin: 10rpx 0rpx;"></view>
			<!-- bottom desc -->
			<view class="bottom-desc">
				工1件商品，合计￥18
			</view>
		</view>
		<!-- 订单信息 -->
		<view class="order">
			<view class="title">
				订单信息
			</view>
			<view style="width: 100%; height: 1rpx; background-color: #f8f8f8; margin: 10rpx 0rpx;"></view>
			<view class="content">
				<view class="item">
					<span>下单时间：</span>
					<text class="bold">2025-12-11</text>
				</view>
				<view class="item">
					<span>取单号：</span>
					<text class="bold">A12</text>
				</view>
				<view class="item">
					<span>订单编号：</span>
					<text class="bold">123</text>
				</view>
				<view class="item">
					<span>商品备注：</span>
					<text class="bold">少糖</text>
				</view>
			</view>
		</view>
		<!-- return -->
		<text style="text-align: center; font-size: 12px; font-weight: bold; color: #bababa; display: block; padding: 20rpx;">如需退款，请联系门店</text>
	</view>
</template>

<script>
	export default {
		data() {
			return {

			}
		},
		methods: {
			phone(code){
				uni.makePhoneCall({
					phoneNumber: code //仅为示例
				});
			}
		}
	}
</script>
<style>
	page {
		background-color: #f2f2f2;
	}
</style>

<style scoped lang="less">
	.order {
		width: 90%;
		margin: 0px auto;
		background-color: #fff;
		border-radius: 10rpx;
		margin-top: 20rpx;

		.title {
			padding: 20rpx;
			font-size: 18px;
			font-weight: bold;
		}

		.content {
			padding-bottom: 20rpx;
			.item {
				padding: 20rpx 20rpx 00rpx 20rpx;
				display: flex;
				justify-content: flex-start;
				align-items: center;

				span {
					font-size: 16px;
					color: #bababa;
					width: 250rpx;
				}

				.bold {
					color: black;
					width: 100% !important;
				}
			}
		}
	}

	.proInfo {
		width: 90%;
		margin: 0rpx auto;
		background-color: #fff;
		border-radius: 10rpx;

		.bottom-desc {
			text-align: end;
			font-size: 16px;
			color: #bababa;
			padding: 20rpx;
		}

		.total {
			display: flex;
			justify-content: space-between;
			align-items: center;

			.left {
				font-size: 16px;
				color: #bababa;
				padding: 20rpx;
			}

			.right {
				font-size: 16px;
				color: black;
				padding: 20rpx;
			}
		}

		.payinfo {
			padding: 20rpx;
			display: flex;
			justify-content: space-between;

			image {
				width: 100rpx;
				height: 100rpx;
			}

			text {
				flex-grow: 1;
				font-size: 16px;
				//font-weight: bold;
				text-align: start;
				color: black;
				margin-left: 20rpx;
			}

			.right {
				display: flex;
				flex-direction: column;
				align-items: flex-end;

				.price {
					color: black;
					font-size: 16px;
					//font-weight: bold;
				}

				.desc {
					margin-top: -30rpx;
					font-size: 12px;
					color: #bababa;
				}
			}
		}

		.shop {
			padding: 20rpx;
			display: flex;
			justify-content: space-between;
			align-items: center;

			.detail {
				text-align: start;

				h1 {
					font-size: 18px;
					font-weight: 600;
					color: black;
				}

				p {
					margin-top: 10rpx;
					font-size: 12px;
					color: #bababa;
				}
			}

			.icons {
				margin-bottom: 25rpx;
			}
		}
	}

	.status {
		width: 90%;
		text-align: center;
		border-radius: 10rpx;
		background-color: #fff;
		margin: 20rpx auto;

		h1 {
			font-size: 18px;
			font-weight: 600;
			color: black;

			padding: 40rpx 20rpx 20rpx 20rpx;
		}

		text {
			font-size: 12px;
			color: #bababa;
			padding-bottom: 40rpx;
			display: block;
		}
	}
</style>